<h1><?php echo $title ?></h1>

<?php if ($notice = $this->session->flashdata('notification')):?>
<p class="notice"><?php echo $notice;?></p>
<?php endif;?>
<?php if ($this->album->album_settings->user_can_create || $this->user->level['album'] >= LEVEL_ADD) : ?>
<div><?php echo anchor('album/ampidiro', __("Create an album", "album")) ?></div>
<?php endif; ?>
<?php if($rows): ?>
<?php if (!$this->user->logged_in) : ?>
<p><?php echo __("These albums can be viewed by everybody. Please log in to view other albums", $module) ?></p>
<?php endif; ?>

<table class="flickr-album" cellspacing=5>
<tbody>
<tr>
<?php $i=1; foreach ($rows as $row) : ?>				
<td class="flickr-row" valign="top" width="<?php echo round(100 / $this->album->album_settings->album_col_num) ?>%">
<a href='<?php echo site_url('album/asehoy/' . $row['aid']) ?>' title='<?php echo $row['title']?>'>
<img align="left" class="thumbnail" alt="<?php echo $row['title'] ?>" src="<?php echo (($row['cover'])? $row['cover'] : base_url() . 'media/images/album/no_image_s.jpg') ?>" />
</a>
<?php echo anchor('album/asehoy/' . $row['aid'], $row['title']) ?><br />
<?php echo (isset($row['description']) ? substr(strip_tags($row['description']), 0, 200) . "..." : "") ?><br />
</td>
<?php if ($i % $this->album->album_settings->album_col_num == 0) echo "</tr><tr>" ; ?> 				       					
<?php $i++; endforeach ; ?>
</table>
<?php echo $pager ?>
<?php else: ?>
<?php echo __("No album found", "album")?>
<?php endif;?>